package club.ljwang.wechat;

import club.ljwang.constant.MessageConstant;
import club.ljwang.entity.Result;
import club.ljwang.pojo.Member;
import club.ljwang.service.MemberService;
import com.alibaba.dubbo.config.annotation.Reference;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @description:
 * @author: ming
 * @date: 2020/3/8-21:42
 * @Version: 1.0.0
 */
@RestController
@RequestMapping("member")
public class MemberController {

    @Reference
    private MemberService memberService;


    @RequestMapping("getFamily")
    public Result getFamily(@club.ljwang.interceptor.Member Member member ){
      List<Member> members =  memberService.getFamily(member.getId());
      return new Result(true,"",members);
    }
}
